package com.xuelang.pipeline.artifact.client.common.request;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import jakarta.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * 分页查询参数
 *
 * @author xiwen.zxg
 * @since 2024/5/16
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class PageParam<T> implements Serializable {

    private static final long serialVersionUID = 1L;
    /**
     * 当前页
     */
    @NotNull(message = "当前页不能为空")
    private Long currentPage;
    /**
     * 每页大小
     */
    @NotNull(message = "每页大小不能为空")
    private Long pageSize;
    /**
     * 查询条件
     */
    private T condition;
    /**
     * 排序字段
     */
    //private String sortField;
    /**
     * 排序方式
     */
    //private String sortOrder;

}
